import java.util.HashMap;

public class Alcohol {
  public String punish( String[] schedule ) {

  HashMap<String, Integer> map = new HashMap<String, Integer>();
  for ( String str:schedule ) {
     if( !map.containsKey(str) )
       map.put(str, 1);
     else
       map.put(str, (map.get(str)+1));
     if( map.get(str) >= 3 )
       return str;
      }
      return "";
 }
 
}